<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui">

<h:head></h:head>
<body>
	<ui:composition template="/template/template.xhtml">
		<ui:define name="title">#{aqarMsgs.Aqarat_Apartments_ApartmentDetails_PageTitle}</ui:define>
		<ui:define name="manuBar">
			<ui:include src="/controlling/aqarat/aqaratMenu.xhtml" />
		</ui:define>

		<ui:define name="content">
			<p:panel header="#{aqarMsgs.Aqarat_Apartments_ApartmentDetails_ApartmentDetails}">
				<h:form id="apartDetails_frm">
					<p:panelGrid columns="2">
						<h:outputText value="#{aqarMsgs.Aqarat_Building_Name}" />
						<h:outputText
							value="#{apartmentBean.apartment.floor.building.name}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_No}" />
						<h:outputText value="#{apartmentBean.apartment.no}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_FloorNo}" />
						<h:outputText value="#{apartmentBean.apartment.floor.no}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_ReservationStatus}" />
						<h:outputText
							value="#{apartmentBean.apartment.reservationStatus.name}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_ConstructStatus}" />
						<h:outputText
							value="#{apartmentBean.apartment.constructtStatus.name}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_TaxesStatus}" />
						<h:outputText value="#{apartmentBean.apartment.taxessStatus.name}" />


						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_ContractDate}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />
						<h:outputText value="#{apartmentBean.apartment.contractDate}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_NoOfPayments}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />
						<h:outputText value="#{apartmentBean.apartment.noOfPayments}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Customer_Name}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />
						<h:outputText value="#{apartmentBean.apartment.customer.name}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_Price}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />
						<h:outputText value="#{apartmentBean.apartment.price}"
							rendered="#{apartmentBean.apartment.reserveStatus == 3}" />

						<h:outputText value="#{aqarMsgs.Aqarat_Apartments_Price}"
							rendered="#{apartmentBean.apartment.reserveStatus == 4}" />

						<p:inputText value="#{apartmentBean.apartment.price}"
							rendered="#{apartmentBean.apartment.reserveStatus == 4}"
							required="true" requiredMessage="You have to enter First Payment"
							converterMessage="Sale Price must be Number">
							<f:converter converterId="javax.faces.Number" />
						</p:inputText>
					</p:panelGrid>
					<p:commandButton value="#{aqarMsgs.Aqarat_General_Save}"
						actionListener="#{apartmentBean.saveApartment}"
						rendered="#{apartmentBean.apartment.reserveStatus == 4}"
						onstart="waiteDialog.show();" oncomplete="waiteDialog.hide();"
						update="msgs" />
					<p:messages id="msgs" />
				</h:form>
			</p:panel>
		</ui:define>
	</ui:composition>
</body>
</html>
